package cn.zn.modules.report.controller;

import cn.zn.framework.common.utils.Result;
import cn.zn.modules.expense.service.TpMainService;
import cn.zn.modules.report.vo.ReportCashierVo;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @author zn
 * @email zhunahao@qq.com
 * @date 2019-12-07
 */
@RestController
@RequestMapping("api/report")
@RequiredArgsConstructor(onConstructor = @__(@Autowired))
@Slf4j
public class ReportController {

    final private TpMainService tpMainService;

    @GetMapping("reportCashier")
    public Result<List<ReportCashierVo>> reportCashier() {
        return Result.ok(tpMainService.findReportCashier());
    }
}
